1. Field of Technology
The present invention relates to a data processing device such as a printer or scanner that has a maintenance counter function.
2. Description of Related Art
Data processing devices such as printers and scanners commonly have a maintenance counter for monitoring the use of parts that wear out over time as a result of normal use, such as the print head and paper transportation rollers, in order to determine the service life of those parts. When a thermal printing mechanism is used, the maintenance counter counts print head usage based on the length of paper advanced passed the print head or the number of drive pulses applied to the thermal head, for example. The usage count is then stored and accumulated in nonvolatile memory, and if the cumulative total usage count exceeds a predetermined level, the user is prompted to replace the print head or other worn parts by reporting an alarm, for example.
The printer taught in Japanese Unexamined Patent Appl. Pub. H06-155867, for example, has a first maintenance counter that is cleared by replacing a consumable product, and a second maintenance counter that is not cleared when the consumable being monitored is replaced and instead continues accumulating the total usage count. The first maintenance counter in this printer is used as a trigger for predicting the end of the service life of the monitored consumable and prompting the user to replace the consumable, and the second maintenance counter measures the cumulative total usage from the time the printer was shipped from the factory in order to manage total cumulative usage.
Products using this type of maintenance counter are built so that the data is not lost when power is not supplied.
The thermal printer taught in Japanese Unexamined Patent Appl. Pub. H06-312559, for example, has a power failure detection circuit that monitors the power supply voltage and outputs a power failure signal when a voltage drop in the power supply voltage is detected. When a power failure occurs and the power failure signal is output, the maintenance counter reading in RAM is written to nonvolatile EEPROM before printing stops and power is lost completely so that the maintenance counter can be stored and is not lost when the power turns off.
Because the maintenance counter is used to determine when the end of the service life of a particular component has been reached, the count of the maintenance counter must be retained even when the power supply is suddenly interrupted, such as when a power failure occurs, as described in Japanese Unexamined Patent Appl. Pub. H06-312559. However, in order to write the maintenance counter count stored in RAM to a nonvolatile EEPROM device after the power fails and before power is completely lost, voltage sufficient to enable the controller to function and write to EEPROM before the power turns off must be assured. Even if the controller is programmed to backup data from RAM to EEPROM, the control program will not function and the count will therefore be lost if sufficient voltage is not assured.
In practice, additional components must be provided in order to reliably write data to EEPROM if a power failure occurs or the power supply is interrupted while writing. This requires an arrangement, such as an auxiliary power supply or uninterruptable power supply, that can assure voltage sufficient to write from RAM to EEPROM after a power failure occurs. Improving reliability by such means necessarily increases the complexity of the circuit design, increases device size, and increases product cost.
In addition, writing to EEPROM can fail for other reasons. If writing to EEPROM fails and content is lost from the EEPROM device, maintenance counter information accumulated over a period of years may also be lost, and when the monitored parts must be replaced will therefore be unknown.
The present invention is directed to solving this problem, and an object of the invention is to provide a data processing device comprising a maintenance counter that can reliably store the maintenance count information under any conditions.